home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part1 / 1005 < prev    next >
Encoding:
Text File  |  1996-08-06  |  1.1 KB  |  57 lines

  1. Path: mail2news.demon.co.uk!jprassoc.demon.co.uk
  2. From: J Paul Robertson <Paul@jprassoc.demon.co.uk>
  3. Newsgroups: comp.lang.c++
  4. Subject: problem with inline
  5. Date: Mon, 08 Jan 96 17:56:30 GMT
  6. Organization: Myorganisation
  7. Message-ID: <821123790snz@jprassoc.demon.co.uk>
  8. Reply-To: Paul@jprassoc.demon.co.uk
  9. X-NNTP-Posting-Host: jprassoc.demon.co.uk
  10. X-Newsreader: Demon Internet Simple News v1.29
  11. X-Mail2News-Path: jprassoc.demon.co.uk
  12.  
  13. Can someone help me out here ?
  14.  
  15. I'm getting an error message from the linker when I declare one of my
  16. functions as inline.
  17.  
  18. The compiler is MSVC 1.52
  19. The error message is:
  20. MAIN.OBJ(c:\temp\main.cpp) : error L2029:
  21. 'public: void __far __pascal vga::blt_screen(void)__far' : unresolved external
  22.  
  23.  
  24. Here's a snippet of code:
  25.  
  26. MAIN.CPP:
  27. #include "vga.h"
  28. // ...
  29.     VGA.wait_for_vsync();
  30.     VGA.blt_screen();
  31. // ...
  32.  
  33. VGA.H:
  34. class vga
  35. {
  36. public:
  37. // ...
  38.     void wait_for_vsync(void);
  39.     void blt_screen(void);
  40.  
  41. private:
  42.     unsigned char far *video_buffer;
  43.     unsigned char far *double_buffer;
  44. };
  45.  
  46. VGA.CPP:
  47. // ...
  48. inline void vga::blt_screen(void)
  49. {
  50.     _fmemcpy( video_buffer, double_buffer, 64000 );
  51. }
  52. // ...
  53.  
  54. Thanks in advance,
  55. -- 
  56. Paul Robertson
  57.